package com.mtf.verifySign.controller;

import com.mtf.common.vo.Result;
import com.mtf.verifySign.entity.TestSecretSaveParam;
import com.mtf.verifySign.service.IKeyService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

/**
 * @Description: verify_sign_key
 * @Author: jeecg-boot
 * @Date: 2023-11-02
 * @Version: V1.0
 */
@Api(tags = "verify_sign_key")
@RestController
@RequestMapping("/test")
@Slf4j
public class KeyController {

    @Autowired
    private IKeyService keyService;

    @ApiOperation("测试秘钥访问接口")
    @PostMapping("/testSecretSaveLog")
    public Result<String> testSecretSaveLog(@Validated @RequestBody TestSecretSaveParam param){

        keyService.validateSign(param);

        return Result.ok("成功访问接口");
    }

}
